1. Field of the Invention
The present invention relates to the technical field of an apparatus capable of proper restoration even if a trouble such as shutdown of power supply occurs during recording or erasing data.
2. Description of the Related Art
In a hard disk (hereinafter referred to as “an HDD”) included in a personal computer or the like as standard equipment, data has been conventionally recorded in a unit of a cluster (which is a minimum unit in recording data in the disk). Data having too large a capacity to be recorded in one cluster is separately stored in a plurality of clusters. In the HDD, the use status of the clusters is managed based on a file allocation table (hereinafter abbreviated as “an FAT”). Therefore, the data is read, written or erased along a chain of clusters based on information stored in the FAT. Consequently, if the FAT is broken, the data recorded in the HDD cannot be read out. As the countermeasures against this, the HDD includes two FATs, i.e., a main FAT and a sub FAT, so that as soon as the main FAT is updated, the sub FAT can be automatically updated. As a result, even if a severe accident occurs while the FAT is rewritten, such an inconvenience that the contents of the HDD cannot be read out is prevented as possible.
In the case where a trouble such as power shutdown of power supply occurs during recording or erasing the data in the conventional personal computer or the like, disk scanning has been known as one of restoring measures thereafter. By such disk scanning, deficient data within a data recording region is searched by looking into the entire FAT region. The deficient data is consistently restored each time the deficient data is detected. Furthermore, if the main FAT and the sub FAT are inconsistent with each other, they are made to be consistent with each other.
However, since the entire FAT region is looked into in the above-described disk scanning, it takes much time to restore all of the data, and moreover, there is no guarantee that the data per se can be securely restored since the FAT region per se is possibly broken. Even if the above-described disk scanning is applied to a recording apparatus equipped with the HDD, it takes much time to look into the entire FAT region and search the deficient data.
Additionally, for example, if the trouble such as the power shutdown of the power supply occurs while a music stream is recorded in the HDD, a data recording region becomes out of unconformity. That is to say, the music stream is recorded in a cluster unit in the data recording region, so that the data cannot be recorded in a cluster in which the data is to be recorded if the FAT region is broken at the time of restoration. Thus, the data lacks of the feature of a stream.